import type { LoginParams, LoginResponse } from '@/api'
import { http } from '@/api'

// 系统 API
export const sysApi = {
  // 修改密码
  updatePassword() {
    return http.post('/api/tapi/sys/password/update')
  },
  // 忘记密码重置
  resetPassword() {
    return http.post('/api/tapi/sys/password/reset')
  },
  // 退出登录
  logout() {
    return http.post('/api/tapi/sys/logout')
  },
  // 账号登录
  login(params: LoginParams) {
    return http.post<LoginResponse>('/api/tapi/sys/login', params)
  },
}
